canonicalize the name of the "activate-slider" style property and use
authorMichael Natterer <mitch@imendio.com>
Thu, 18 May 2006 11:39:42 +0000 (11:39 +0000)
committerMichael Natterer <mitch@src.gnome.org>
Thu, 18 May 2006 11:39:42 +0000 (11:39 +0000)
2006-05-18  Michael Natterer  <mitch@imendio.com>

* gtk/gtkrange.c: canonicalize the name of the "activate-slider"
style property and use GTK_PARAM_READABLE instead of
G_PARAM_READABLE. Moved one "activate_slider" variable to the
local scope its used in.

ChangeLog
ChangeLog.pre-2-10
gtk/gtkrange.c

index ed500ccb9a4acf1158aa43813e154ed9c2217fb1..f0645b183fe7c4a7503989e1481d4a6bcf886bd1 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2006-05-18  Michael Natterer  <mitch@imendio.com>
+
+       * gtk/gtkrange.c: canonicalize the name of the "activate-slider"
+       style property and use GTK_PARAM_READABLE instead of
+       G_PARAM_READABLE. Moved one "activate_slider" variable to the
+       local scope its used in.
+
 2006-06-18  Michael Emmel  <mike.emmel@gmail.com>
 
        * gdk/directfb/gdkscreen-directfb.c: 
index ed500ccb9a4acf1158aa43813e154ed9c2217fb1..f0645b183fe7c4a7503989e1481d4a6bcf886bd1 100644 (file)
@@ -1,3 +1,10 @@
+2006-05-18  Michael Natterer  <mitch@imendio.com>
+
+       * gtk/gtkrange.c: canonicalize the name of the "activate-slider"
+       style property and use GTK_PARAM_READABLE instead of
+       G_PARAM_READABLE. Moved one "activate_slider" variable to the
+       local scope its used in.
+
 2006-06-18  Michael Emmel  <mike.emmel@gmail.com>
 
        * gdk/directfb/gdkscreen-directfb.c: 
index fffe05e21ca94fcd7b5e88b79c6e412b5df21653..51199cb33ea01fa1c4db8feccc8a2163214f50ea 100644 (file)
@@ -393,11 +393,11 @@ gtk_range_class_init (GtkRangeClass *class)
                                                             GTK_PARAM_READABLE));
 
   gtk_widget_class_install_style_property (widget_class,
-                                          g_param_spec_boolean ("activate_slider",
+                                          g_param_spec_boolean ("activate-slider",
                                                                  P_("Draw slider ACTIVE during drag"),
                                                                 P_("With this option set to TRUE, sliders will be drawn ACTIVE and with shadow IN while they are dragged"),
                                                                 FALSE,
-                                                                G_PARAM_READABLE));
+                                                                GTK_PARAM_READABLE));
 }
 
 static void
@@ -1134,7 +1134,6 @@ gtk_range_expose (GtkWidget      *widget,
   gint focus_line_width = 0;
   gint focus_padding = 0;
   gboolean touchscreen;
-  gboolean activate_slider;
 
   g_object_get (gtk_widget_get_settings (widget),
                 "gtk-touchscreen-mode", &touchscreen,
@@ -1203,8 +1202,10 @@ gtk_range_expose (GtkWidget      *widget,
 
   if (range->layout->grab_location == MOUSE_SLIDER)
     {
-      gtk_widget_style_get (widget, "activate_slider", &activate_slider, NULL);
-      
+      gboolean activate_slider;
+
+      gtk_widget_style_get (widget, "activate-slider", &activate_slider, NULL);
+
       if (activate_slider)
         {
           state = GTK_STATE_ACTIVE;
@@ -1518,13 +1519,15 @@ gtk_range_button_press (GtkWidget      *widget,
         }
 
       range_grab_add (range, MOUSE_SLIDER, event->button);
-      
-      gtk_widget_style_get (widget, "activate_slider", &activate_slider, NULL);
-      
-      /* force a redraw, if the active slider is drawn differently to the prelight one */
+
+      gtk_widget_style_get (widget, "activate-slider", &activate_slider, NULL);
+
+      /* force a redraw, if the active slider is drawn differently to the
+       * prelight one
+       */
       if (activate_slider)
         gtk_widget_queue_draw (widget);
-      
+
       if (need_value_update)
         update_slider_position (range, event->x, event->y);